﻿@{
    ViewBag.Title = "分类皮肤管理";
    Layout = "~/Views/Shared/_AdminLayout.cshtml";
}
<style>
    .margin-left1
    {
        padding-left:00px;
        font-weight:bold;
        font-size:14px;       
     }
     .margin-left2
    {
       padding-left:30px;
        font-weight:bold;
        font-size:12px;
     }
      .margin-left3
    {
        padding-left:60px;
        font-size:12px;
     }
</style>
@model List<UcAsp.Net.Model.Select>
<div class="container-fluid">
    <div class="row-fluid">
        <button id="addcontent" class="btn btn-danger" data-id="@ViewData["ParentID"]">
            添加</button>
        <div class="span12">
            <div id="breadcrumb">
                @foreach (UcAsp.Net.Model.CategoriesTree tree in (List<UcAsp.Net.Model.CategoriesTree>)ViewData["Categories"])
                { 
                    <a href="CategoriesManger?ID=@tree.ID"  class="tip-bottom">@tree.CategorieName</a>
                }
            </div>
            <div class="widget-box">
                <div class="widget-title">
                    <span class="icon"><i class="icon-th"></i></span>
                    <h5>
                        类目管理</h5>
                </div>
                <div class="widget-content nopadding">
                    <table class="table table-bordered table-striped">
                        <thead>
                            <tr>
                                <th>
                                    类目名称
                                </th>
                                <th>
                                    操作
                                </th>
                            </tr>
                        </thead>
                        <tbody>
                            @foreach (UcAsp.Net.Model.Select art in Model)
                            {
                                <tr>
                                    <td>
                                    <div  class="margin-left@{@art.Depth}">
                                       <a href="/Admin/CategoriesThemes?ID=@art.Value">@art.Name</a>
                                     </div>                                        
                                    </td>
                                    <td>
                                        <button   class="btn btn-primary advedit" data-id="@art.Value">
                                            <i class="icon-pencil icon-white"></i>分类广告设置</button>
                                        <a href="/Admin/SubjectManage?CId=@art.Value&theme=@Request["theme"]">
                                            <button  class="btn btn-primary setting" data-id="@art.Value">
                                                <i class="icon-road icon-white"></i>分类主题设置</button>
                                        </a>
                                        <button   class="btn btn-primary advmessageedit" data-id="@art.Value">
                                            <i class="icon-pencil icon-white"></i>内容广告设置</button>
                                        <a href="/Admin/SubjectManage?CId=@art.Value&Message=show&theme=@Request["theme"]">
                                            <button  class="btn btn-primary setting" data-id="@art.Value">
                                                <i class="icon-road icon-white"></i>内容主题设置</button>
                                        </a>
                                    </td>
                                </tr>
                            }
                        </tbody>
                    </table>
                </div>
            </div>
        </div>
    </div>
</div>
<script>
    $(document).ready(function () {
        ///修改分类信息
        $(".advedit").click(function () {
            window.location.href = "/Admin/AdvManage?theme=@Request["theme"]&Id=" + $(this).attr("data-id");

        });

        $(".advmessageedit").click(function () {
            window.location.href = "/Admin/AdvManage?theme=@Request["theme"]&Message=show&Id=" + $(this).attr("data-id");            
        });
    });
</script>
